﻿@section PageTitle { Website Screenshot Layer }

<p class="summary">
	Install the <a href="http://nuget.org/packages/DynamicImage.Extensions.WebsiteScreenshot/">DynamicImage.Extensions.WebsiteScreenshot</a> package to get this extension.
	There is some background information in <a href="http://timjones.tw/blog/archive/2010/11/04/creating-website-thumbnail-images-in-aspnet">this blog post</a>.
</p>

<pre class="prettyprint">
@@Html.DynamicImageTag(b => b.WithLayer(
	new WebsiteScreenshotLayerBuilder().WebsiteUrl("http://www.apple.com")
		.Timeout(15000).BrowserWidth(1024)
		.WithFilter(FilterBuilder.Resize.ToWidth(500))
		.WithFilter(FilterBuilder.Border.Width(1).Fill(Colors.Black))
		.WithFilter(FilterBuilder.DropShadow)
))
</pre>

<p>
	@Html.DynamicImageTag(b => b.WithLayer(
		new WebsiteScreenshotLayerBuilder().WebsiteUrl("http://www.apple.com")
            .Timeout(15000).BrowserWidth(1024)
			.WithFilter(FilterBuilder.Resize.ToWidth(500))
			.WithFilter(FilterBuilder.Border.Width(1).Fill(Colors.Black))
			.WithFilter(FilterBuilder.DropShadow)
	))
</p>